package com.itown.expo.controller;

import java.util.HashMap;
import java.util.Map;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.web.servlet.ModelAndView;
import org.springframework.web.servlet.view.RedirectView;

import com.itown.expo.controller.base.MyBaseCommandController;
import com.itown.expo.model.CcyRate;

public class CcyRateEditController extends MyBaseCommandController {

	@Override
	protected ModelAndView handleInner(HttpServletRequest request,
			HttpServletResponse response, Object command) {
		CcyRate ccy = (CcyRate) command;
		Map map = new HashMap();
		getServiceContainer().getSettingService().updateCcyRate(ccy);
		return new ModelAndView(new RedirectView("CcyRateList.do?id="
				+ ccy.getId()), "map", map);
	}
}
